#ifndef SNAPOPERATION_H
#define SNAPOPERATION_H

#include <QObject>
#include <QDebug>
#include "operation.h"
#include "description.h"
#include <QJsonObject>

class SnapOperation : public Operation
{
    Q_OBJECT
public:
    explicit SnapOperation(QObject *parent = nullptr);

private:
    // 编号
    int             m_nImageNum;
    Description*    m_pDescription;

public:
    int             GetImageNum(){return m_nImageNum;}
    Description*    GetDescription(){return m_pDescription;}

public:
    virtual Operation* clone(Operation* pOperation) override;
    virtual void run() override;

    virtual void writeXML(QXmlStreamWriter& writer) override;
    virtual void readFromXML(QXmlStreamReader& reader) override;

    virtual QString getClassName() override;

public:
    int nImageNum() const;
    void setNImageNum(int newNImageNum);
};

#endif // SNAPOPERATION_H
